<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:f="http://xmlns.jcp.org/jsf/core"
      xmlns:p="http://primefaces.org/ui">

    <ui:composition>

        <p:dialog id="AeroportoCreateDlg" widgetVar="AeroportoCreateDialog" modal="true" resizable="false" appendTo="@(body)" header="#{bundle.CreateAeroportoTitle}">
            <h:form id="AeroportoCreateForm">
                <h:panelGroup id="display">
                    <p:panelGrid columns="2" rendered="#{aeroportoController.selected != null}">
                        <p:outputLabel value="#{bundle.CreateAeroportoLabel_sgAeroporto}" for="sgAeroporto" />
                        <p:inputText id="sgAeroporto" value="#{aeroportoController.selected.sgAeroporto}" title="#{bundle.CreateAeroportoTitle_sgAeroporto}" required="true" requiredMessage="#{bundle.CreateAeroportoRequiredMessage_sgAeroporto}"/>
                        <p:outputLabel value="#{bundle.CreateAeroportoLabel_nmAeroporto}" for="nmAeroporto" />
                        <p:inputText id="nmAeroporto" value="#{aeroportoController.selected.nmAeroporto}" title="#{bundle.CreateAeroportoTitle_nmAeroporto}" required="true" requiredMessage="#{bundle.CreateAeroportoRequiredMessage_nmAeroporto}"/>
                        <p:outputLabel value="#{bundle.CreateAeroportoLabel_sgEstado}" for="sgEstado" />
                        <p:inputText id="sgEstado" value="#{aeroportoController.selected.sgEstado}" title="#{bundle.CreateAeroportoTitle_sgEstado}" required="true" requiredMessage="#{bundle.CreateAeroportoRequiredMessage_sgEstado}"/>
                        <p:outputLabel value="#{bundle.CreateAeroportoLabel_nmCidade}" for="nmCidade" />
                        <p:inputText id="nmCidade" value="#{aeroportoController.selected.nmCidade}" title="#{bundle.CreateAeroportoTitle_nmCidade}" required="true" requiredMessage="#{bundle.CreateAeroportoRequiredMessage_nmCidade}"/>
                    </p:panelGrid>
                    <p:commandButton actionListener="#{aeroportoController.create}" value="#{bundle.Save}" update="display,:AeroportoListForm:datalist,:growl" oncomplete="handleSubmit(args,'AeroportoCreateDialog');"/>
                    <p:commandButton value="#{bundle.Cancel}" onclick="AeroportoCreateDialog.hide()"/>
                </h:panelGroup>
            </h:form>
        </p:dialog>

    </ui:composition>
</html>
